<!DOCTYPE HTML>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<meta charset="utf-8">
<head th:include="include :: header"></head>
</head>
<body class="gray-bg">
<div class="wrapper wrapper-content">
    <div class="btn-group hidden-xs" id="toolbar" role="group">
        <button type="button" class="btn btn-outline btn-default" onclick="add()"
                shiro:hasPermission="manage:questionBank:add">
            <i class="fa fa-plus"></i> 新增
        </button>
        <button type="button" class="btn btn-outline btn-default" onclick="batchRemove()"
                shiro:hasPermission="manage:questionBank:batchRemove">
            <i class="fa fa-trash-o"></i> 删除
        </button>
        <!-- 触发模态框的按钮 -->
        <button type="button" class="btn btn-primary" data-toggle="modal" data-target="#exampleModal">
            上传文件
        </button>
    </div>
    <table class="bootstrap-table" data-mobile-responsive="true">
    </table>
</div>

<div class="modal fade" id="exampleModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel"
     aria-hidden="true">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title" id="exampleModalLabel">文件上传</h5>
                <button type="button" class="close" data-dismiss="modal" aria-label="关闭">
                    <span aria-hidden="true">&times;</span>
                </button>
            </div>
            <form style="margin-left: 30px">
                <input type="file" id="fileUpload" name="file">
            </form>
            <div class="modal-footer">
                <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
                <button type="button" class="btn btn-primary" onclick="uploadFile()">提交</button>
            </div>
        </div>
    </div>
</div>

<div th:include="include :: footer"></div>
<script src="/reasahi/manage/questionBank/questionBank.js"
        th:src="@{/reasahi/manage/questionBank/questionBank.js}"></script>
<script th:inline="javascript">
    var editFlag = [[${@permissionService.hasPermi('manage:questionBank:edit')}]];
    var removeFlag = [[${@permissionService.hasPermi('manage:questionBank:remove')}]];

</script>
</body>
</html>